#include <iostream>
#include <vector>
// #include <bits/stdc++.h>

using namespace std;
#define int long long
#define endl "\n"
const int INF = 0x3f3f3f3f3f;

signed main()
{
    ios::sync_with_stdio(0);
    cin.tie(0);
    cout.tie(0);
    //cout << 1 << endl << 2 << endl;
    int n = 0, m = 0;
    cin >> n >> m;
    int sum = 0;
    for(int i = m; i <= n; ++i)
    {
        int x = 0;
        cin >> x;
        sum += x;
    }
    cout << double(sum + m) / n << endl;
    cout << double(sum + m * 5) / n << endl;
    return 0;
}